import http from "./request"

// 通过专业id获取班级列表
export const getClassListApi = async parm => {
    return await http.get('/api/student/getClassList', parm)
}

// 新增学生
export const addStudentApi = async parm => {
    return await http.post('/api/student', parm)
}

// 获取学生列表
export const getListApi = async parm => {
    return await http.get('/api/student/list', parm)
}

// 编辑回显查询
export const getByIdApi = async parm => {
    return await http.get('/api/student/getById', parm)
}

// 编辑
export const editStudentApi = async parm => {
    return await http.put('/api/student', parm)
}

// 删除
export const deleteStudentApi = async parm => {
    return await http.delete('/api/student', parm)
}

// 查询角色列表
export const getRoleListApi = async () => {
    return await http.get('/api/student/getRoleList', null)
}

//通过班级id获取对应班级下面的学生
export const getClassByClassIdApi = async (parm) => {
    return await http.get('/api/student/getClassByClassId', parm)
}

// 重置密码
export const resetPasswordApi = async parm => {
    return await http.post('/api/student/resetPassword', parm)
}